package com.itboye.eweilisten.util;

import android.app.Activity;
import android.widget.LinearLayout;

/**
 * Created by Mr.w on 2017/3/1.
 */

public class ScreenUtil {
    public static int getWidh(Activity context) {
        return context.getWindowManager().getDefaultDisplay().getWidth();
    }

    public static int getHeight(Activity context) {
        return context.getWindowManager().getDefaultDisplay().getHeight();
    }
    public static int getWrapContent() {
        return LinearLayout.LayoutParams.WRAP_CONTENT;
    }
    public static LinearLayout.LayoutParams getWrapLayoutParams() {
        LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.WRAP_CONTENT, LinearLayout.LayoutParams.WRAP_CONTENT);
        return layoutParams;
    }
}
